<template>
  <div @click="$emit('goDetail')" class="box1">
    <img :src=src />
    <p class="title">{{ title }}</p>
    <p class="price">{{ price }}币</p>

  </div>
</template>

<script setup>

defineEmits(['goDetail'])

defineProps({
  title: {
    default: '标题'
  },
  price: {
    default: 200
  },
  src: {
    type: String
  }

})


</script>

<style scoped>
img {
  width: 40vw;
  height: 40vw;
}

.title {
  font-size: 2.267vw;
  margin-top: 1.333vw;
}

.price {
  font-size: 2.4vw;
  font-weight: bold;
  margin: 1.333vw 0;
}

.box1 {
  margin-left: 50px;
}
</style>